# -*- coding: utf-8 -*-
# Author: areful
#
# pip install grpcio
# pip install protobuf
# pip install grpcio-tools
# ...

# Copyright 2015, Google Inc.
# All rights reserved.

"""The Python implementation of the GRPC helloworld.Greeter client."""

from __future__ import print_function

from bqtool.rpc.algorpc_pb2 import *
from bqtool.rpc.algorpc_pb2_grpc import *


def run():
    channel = grpc.insecure_channel('localhost:50051')
    stub = AlgoapiStub(channel)
    response = stub.invoke(param(data='world',structure='snk'))
    print("Greeter client received: " + response.jsondata)


if __name__ == '__main__':
    run()